﻿using Idea.UnitOfWork.Interface;
using Idea.Unity.Interface;
using Microsoft.Practices.Unity;

namespace Idea.UnitOfWork.Unity.CompositionRoot
{
    public class UnityConfiguration : IUnityConfiguration
    {
        public void Configurate(IUnityContainer container)
        {
            container
                .RegisterType<IUnitOfWorkManager, UnitOfWorkManager>(new ContainerControlledLifetimeManager())
                .RegisterType<IUnitOfWorkFactory, UnitOfWorkFactory>();
        }
    }
}
